import React from "react";

const PhraseList = ({ phrases, onPhraseSelect }) => {
  return (
    <div className="phrase-list">
      <h3>热门语录</h3>
      <div className="phrases">
        {phrases.map((phrase, index) => (
          <button
            key={index}
            onClick={() => onPhraseSelect(phrase)}
            className="phrase-btn"
          >
            {phrase}
          </button>
        ))}
      </div>
    </div>
  );
};

export default PhraseList;
